﻿<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<base href="http://1stjs.googlecode.com/svn/trunk/fw4/" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</meta>
<title>F.drag演示</title>
<style type="text/css">
*{margin:0;padding:0;}
.siege{border:1px solid blue; width:400px; height:400px;}
#redbox{position:absolute; width:100px; height:100px; background-color:red;}
#bluebox{position:absolute; width:100px; height:100px; background-color:blue;}
#greenbar{width:100%; height:20px; background-color:green;}
</style>
<script type="text/javascript" src="1st.js"></script>
</head>
<body>
<div class="siege"></div>
<div id="redbox" style="left:250px; top:250px;"></div>
<div id="bluebox" style="left:50px; top:50px;">
	<div id="greenbar"></div>
</div>

<script type="text/javascript">
F.drag("redbox",{lockY:1}); //简单拖动
F.drag("bluebox",{handle:"greenbar",x1:0,y1:0,x2:400,y2:400}); //复杂拖动
</script>
</body>
</html>